<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Title</title>
</head>
<body>
<script>
var p = {
    name : "李四",
    age : 20,
    girls : ["凤姐", "志玲"]
};

/*p.sex = "男"
console.log(p);
console.log(delete p["girls"])

console.log(p);*/

for(var proName in p){
    console.log(proName, p[proName]);
}



</script>
</body>
</html>
<!--
js是一种动态语言

对象的属性, 可以动态的增加和删除

delete 删除对象的属性

添加到window中的属性, 不能删除(变量不能删除)

for of : 数组, 字符串   set map
-->